/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package dao.tests;

import dao.Articulos;
import excepciones.DAOException;
import objetosNegocio.Articulo;

/**
 *
 * @author rafael
 */
public class test {
    public static void main(String[] args){
        Articulos test=new Articulos();
        test.agrega(new Articulo("123"));
        Articulo t= test.obten(new Articulo("12"));
        System.out.println(t);
        t=new Articulo("123","Test","test2","trst");
        try{
            test.actualiza(t);
        }
        catch(DAOException e){
            System.out.println(e.getCause());
        }
//        //System.out.println(test.obten(t));
//        try{
////            test.elimina(new Articulo("123"));
//        }
////        catch(DAOException e){
//            
//        }
        System.out.println(test.obten(new Articulo("123")));
        
        System.out.println(test.lista("test2"));
    }
}
